Methods and systems for controlling access to a protected resource

ABSTRACT

An electronic device is disclosed. The electronic device includes a memory, a camera module, a communications module, and a processor that is configured to: receive, from the camera module, image data associated with a machine-readable optical label, the optical label encoding transaction details of a transfer of data to a recipient account, wherein the transaction details do not indicate an identity of the recipient account; receive a user input indicating authorization to initiate a transfer of data, via a protected resource, from an account associated with the user to the recipient account; and in response to receiving the user input, generate a request for initiating the transfer of data based on the transaction details, the request including an access token for use in authenticating the user on requests to access the protected resource.

CROSS-REFERENCE TO RELATED APPLICATION

The present application is a continuation of U.S. patent applicationSer. No. 16/038,640 filed on Jul. 18, 2018, which is acontinuation-in-part of U.S. patent application Ser. No. 16/000,086filed on Jun. 5, 2018. The contents of the above-referenced applicationsare incorporated herein by reference in their entirety.

TECHNICAL FIELD

The present disclosure relates to security of data systems and, inparticular, to systems that are designed to perform user authenticationand authorization for accessing protected data sources.

BACKGROUND

Identity and access management (IAM) systems enable user authenticationand authorization across autonomous security domains. Modern IAMsolutions implement open industry standards (e.g. OpenID, OAuth 2.0) toachieve interoperability for common access control processes, such assingle sign-on (SSO) and cross-domain account provisioning. Inparticular, IAM solutions facilitate portability of identity informationto enable users of one domain to access data or systems of anotherotherwise independent domain.

Third-party applications, such as web or mobile applications, mayinterface with IAM systems when attempting to access a protectedresource. For example, a client application executing on a user's mobiledevice may, upon receiving permission from the user, request to accessthe user's resources (e.g. data, services) at a resource server. Theclient application may, for example, request to directly access usercontent at the resource server, or generate an application programminginterface (API) call requesting an operation to be performed at theresource server. An IAM implementation may perform authentication ofsuch client applications. It would be desirable for IAM systems andplatforms to enable secure authentication of client applications foraccessing protected resources, without the need for redundant useradministration.

BRIEF DESCRIPTION OF DRAWINGS

Reference will now be made, by way of example, to the accompanyingdrawings which show example embodiments of the present application andin which:

FIG. 1 is a schematic diagram illustrating an operating environment ofan example embodiment;

FIG. 2 is a high-level operation diagram of an example electronicdevice;

FIG. 3 depicts a simplified software organization of the exampleelectronic device of FIG. 2;

FIG. 4 depicts a simplified organization of software modules exemplaryof an embodiment of a data transfer application;

FIG. 5 is a sequence diagram showing an example process for regulatingaccess to a protected resource by a client application;

FIG. 6 shows, in flowchart form, an example method for regulating accessto a protected resource;

FIG. 7 shows, in flowchart form, an example method for a clientapplication to gain access to a protected resource; and

FIG. 8 shows, in flowchart form, an example method for regulating accessto a protected resource server for requesting transfer of data betweenaccounts at the resource server.

Like reference numerals are used in the drawings to denote like elementsand features.

DETAILED DESCRIPTION OF EXAMPLE EMBODIMENTS

In one aspect, the present disclosure describes an electronic device.The electronic device includes a memory, a camera module, acommunications module, and a processor coupled to the memory. Theprocessor is configured to: receive, from the camera module, image dataassociated with a machine-readable optical label, the optical labelencoding transaction details of a transfer of data to a recipientaccount, wherein the transaction details do not indicate an identity ofthe recipient account; receive a user input indicating authorization toinitiate a transfer of data, via a protected resource, from an accountassociated with the user to the recipient account; and in response toreceiving the user input, generate a request for initiating the transferof data based on the transaction details, the request including anaccess token for use in authenticating the user on requests to accessthe protected resource.

In some implementations, the protected resource may comprise anapplication programming interface that includes instructions forinitiating transfer of data from the account associated with the user tothe recipient account.

In some implementations, the transaction details may not identify theaccount associated with the user or the recipient account.

In some implementations, the machine-readable optical label may comprisea two-dimensional barcode encoding the transaction details of thetransfer of data.

In some implementations, the processor may be further configured tocapture the image data depicting the machine-readable optical label.

In some implementations, the transaction details of the transfer of datamay include a unique identifier of the transfer of data.

In some implementations, the machine-readable optical label may have anexpiry time.

In some implementations, the access token may be received from anauthentication server associated with the protected resource.

In some implementations, the access token may be received in response toa request to the authentication server to verify that first credentialsidentifying the user are authorized for accessing the protectedresource.

In some implementations, the request for initiating the transfer of datamay include at least one of a type or quantity of data to be transferredto the recipient account.

In another aspect, the present disclosure describes acomputer-implemented method. The method includes: receiving, from acamera module of an electronic device, image data associated with amachine-readable optical label, the optical label encoding transactiondetails of a transfer of data to a recipient account, wherein thetransaction details do not indicate an identity of the recipientaccount; receiving a user input indicating authorization to initiate atransfer of data, via a protected resource, from an account associatedwith the user to the recipient account; and in response to receiving theuser input, generating a request for initiating the transfer of databased on the transaction details, the request including an access tokenfor use in authenticating the user on requests to access the protectedresource.

In another aspect, the present disclosure describes an electronicdevice. The electronic device includes a memory, a camera module, acommunications module, and a processor coupled to the memory, thecommunications module, and the camera module. The processor isconfigured to: receive first credentials identifying a user; transmit,via the communications module to an authentication server, a firstsignal including a request to verify that the first credentials areauthorized for accessing a protected resource; when the firstcredentials are authorized for accessing the protected resource,receive, via the communications module from the authentication server, asecond signal including an access token for use in authenticating theuser on requests to access the protected resource; receive, from thecamera module, image data associated with a machine-readable opticallabel, the optical label encoding transaction details of a firsttransaction; and generate a request based on the transaction details toaccess the protected resource for initiating the first transaction, therequest including the access token.

In another aspect, the present disclosure describes a server. The serverincludes, at least, a memory and a processing unit coupled to thememory. The processing unit is configured to: receive first credentialsidentifying a user; receive second credentials identifying a useraccount; associate the first credentials with the user accountidentified by the second credentials; store, in the memory, an accesstoken for use in authenticating the user on requests to access aprotected resource; receive, from a client application executing on afirst device, a request to initiate a first transaction, the requestincluding transaction details derived from a machine-readable opticallabel; verify that the request originated from the user; and in responseto verifying that the request originated from the user, generate arequest based on the transaction details to access the protectedresource for initiating the first transaction, the request including theaccess token.

In another aspect, the present disclosure describes acomputer-implemented method. The method includes: receiving firstcredentials identifying a user; transmitting, to an authenticationserver, a first signal including a request to verify that the firstcredentials are authorized for accessing a protected resource; when thefirst credentials are authorized for accessing the protected resource,receiving, from the authentication server, a second signal including anaccess token for use in authenticating the user on requests to accessthe protected resource; receiving image data associated with amachine-readable optical label, the optical label encoding transactiondetails of a first transaction; and generating a request based on thetransaction details to access the protected resource for initiating thefirst transaction, the request including the access token.

In another aspect, the present disclosure describes a network device.The network device includes a communication interface connected to anexternal network, a memory, and a processing unit coupled to thecommunication interface and the memory. The processing unit isconfigured to receive, via the communication interface from a clientapplication executing on a first device, a first signal including arequest to obtain an access token for accessing a protected resource,where the request includes: a client identifier uniquely identifying theclient application; a user identifier uniquely identifying an end userof the client application; and a public key associated with the enduser. The processing unit is further configured to: in response tovalidating the request, transmit via the communication interface to theclient application on the first device, a second signal including anaccess token for accessing the protected resource; receive, via thecommunication interface from a web server associated with the protectedresource, a third signal including a request to validate a bearer tokensubmitted by the client application to the web server, the bearer tokenincluding a digital signature; validate the bearer token, the validatingincluding verifying the digital signature using the public key; and inresponse to validating the bearer token, send to the web server via thecommunication interface a fourth signal including a notification thatthe bearer token is valid.

In another aspect, the present disclosure describes acomputer-implemented method. The method may, for example, be performedwhen processing requests from client applications to access one or moreprotected resources. The method includes receiving, from a clientapplication executing on a first device, a first signal including arequest to obtain an access token for accessing a protected resource,where the request includes: a client identifier uniquely identifying theclient application; a user identifier uniquely identifying an end userof the client application; and a public key associated with the enduser. The method further includes: in response to validating therequest, transmitting, to the client application on the first device, asecond signal including an access token for accessing the protectedresource; receiving, from a web server associated with the protectedresource, a third signal including a request to validate a bearer tokensubmitted by the client application to the web server, the bearer tokenincluding a digital signature; validating the bearer token, thevalidating including verifying the digital signature using the publickey; and in response to validating the bearer token, sending to the webserver a fourth signal including a notification that the bearer token isvalid.

Other example embodiments of the present disclosure will be apparent tothose of ordinary skill in the art from a review of the followingdetailed descriptions in conjunction with the drawings.

In the present application, the term “and/or” is intended to cover allpossible combinations and sub-combinations of the listed elements,including any one of the listed elements alone, any sub-combination, orall of the elements, and without necessarily excluding additionalelements.

In the present application, the phrase “at least one of . . . or . . . ”is intended to cover any one or more of the listed elements, includingany one of the listed elements alone, any sub-combination, or all of theelements, without necessarily excluding any additional elements, andwithout necessarily requiring all of the elements.

In an aspect, the present application discloses a software architecturefor an authentication and authorization platform. More specifically, aplatform for client authentication and authorization of access to aprotected resource is disclosed. The platform of the present disclosuremay include a mobile security service designed to promote secureauthentication of client applications and verification of accesspermissions. The mobile security service may, for example, beimplemented as an authorization server that functions as an intermediarybetween client applications and a protected resource.

The present application also describes methods and systems enablingtransfer of data between accounts at a resource server. The system maybe built on top of a back-end structure that is provided by theauthentication and authorization platform disclosed herein. The systemmay facilitate enhanced security by requiring multiple layers ofauthentication between client applications and the resource server andby preserving the anonymity of sensitive account information that may beappropriated by a malicious attacker.

Reference is first made to FIG. 1, which shows an exemplary operatingenvironment in accordance with embodiments of the present disclosure.FIG. 1 illustrates an exemplary system for authenticating clients andgranting authorization to access a protected resource 140.

The electronic device 100 is a computer system. In some embodiments, theelectronic device 100 may be a portable electronic device. For example,the electronic device 100 may, as illustrated, be a smartphone. Theelectronic device 100 may be a computing device of another type such asa personal computer, a laptop computer, a tablet computer, a notebookcomputer, a hand-held computer, a personal digital assistant, a portablenavigation device, a mobile phone, a smart phone, a wearable computingdevice (e.g., a smart watch, a wearable activity monitor, wearable smartjewelry, and glasses and other optical devices that include opticalhead-mounted displays), an embedded computing device (e.g., incommunication with a smart textile or electronic fabric), and any othertype of computing device that may be configured to store data andsoftware instructions, and execute software instructions to performoperations consistent with disclosed embodiments. In some embodiments,the electronic device 100 may include a smart card, chip card,integrated circuit card (ICC), and/or other card having an embeddedintegrated circuit.

The electronic device 100 is configured to execute software, such asclient application 102 and web browsers. A client application 102 may,for example, be a web application (e.g. single-page application, orSPA), a mobile application, or a desktop application. The clientapplication 102 may be an app that requests to access a protectedresource 140. In at least some embodiments, the client application 102may request a third-party service to perform authentication on itsbehalf. For example, the client application 102 may have a credentialthat must be authenticated for the client application 102 to be grantedpermission to access the protected resource 140. The client application102 has an identifier uniquely identifying the client application 102.

The network 120 is a computer network. The network 120 allows computersystems in communication therewith to communicate. For example, asillustrated, the network 120 may allow the electronic device 100 tocommunicate with the authentication and authorization platform 130 andthe protected resource 140.

The protected resource 140 is accessible via the network 120. Theprotected resource 140 may be a computer system that includes one ormore database servers, computer servers, and the like. In someembodiments, the protected resource 140 may be an applicationprogramming interface (API) for a web-based system, operating system,database system, computer hardware, or software library.

The authentication and authorization platform 130 is a computer system.The platform 130 may include one or more computing devices such as, forexample, database servers, computer servers, and the like. The computingdevices may be in communication with each other using the network 120.Alternatively, the computing devices may communicate using anothernetwork such as, for example, a local-area network (LAN). In someembodiments, the platform 130 may include multiple computing devicesorganized in a tiered arrangement. For example, platform 130 may includemiddle-tier and back-end computing devices. In some embodiments,platform 130 may be a cluster formed of a plurality of interoperatingcomputing devices.

The authentication and authorization platform 130 may handle a widerange of services relating to user/client authentication, user sessionsmanagement, and authorization. FIG. 1 illustrates a plurality of definedservices that are included as part of the authentication andauthorization platform 130: mobile security service 132, login webservice 134, user session service 136, and identity provider service138. Each of these services may be rendered by independent computersystems, or alternatively, one or more of the services may beimplemented by the same computer system. Furthermore, one or more of theservices may be performed or offered together in the authentication andauthorization platform 130.

The login web service 134 provides authentication verification.Specifically, the login web service 134 may authenticate a user of theelectronic device 100 based on verifying user and/or client credentialsreceived from the electronic device 100. The login web service 134 mayenforce multi-factor authentication policies (if the user has notalready been authenticated), and may maintain a record of authenticatedusers.

The user session service 136 is responsible for handling tasks relatingto user sessions, including, among others, user attributes processing,token revocation, and session revocation. In particular, the sessionservice 136 may, for example, provide an endpoint each for: retrievinguser attributes; revoking “tokens” or security credentials; and revokinguser sessions.

The identity provider service 138 provides a security token service(STS). An STS handles issuing, validating, renewing, and cancellingsecurity tokens. A token issued by the STS can then be used to identifythe holder of the token to services requiring standards-basedauthentication. In some embodiments, the identity provider service 138may comply with the specification of the OpenID Connect standard, anauthentication layer on top of the OAuth 2.0 authorization framework.The identity provider service 138 includes an authorization endpointwhere an end-user is asked to authenticate and grant a clientapplication access to the user's identity. In OAuth 2.0 implementations,a token endpoint of the identity provider service 138 may performverification of a code challenge when exchanging an authorization codefor a set of one or more security tokens.

The mobile security service 132 provides an endpoint each for:exchanging authorization code for a set of security tokens; providingverification of access/bearer tokens; and retrieving refresh tokens andnew access tokens. Accordingly, the mobile security service 132 may beconnected to at least one of a security token service (or animplementation thereof), a client application, and a protected resource(or a server associated therewith).

Other services may be provided by the authentication and authorizationplatform 130. For example, an authentication orchestrator service (notshown) may enforce the protocols for obtaining security tokens, andprovide endpoints for client information retrieval, client registration,and session validation. A user information service (not shown) maygather user attributes from various different sources to build a uniqueview of user information, and ensure that user attributes are maintainedup-to-date.

Returning to the electronic device 100, FIG. 2 is a high-level operationdiagram of the example electronic device 100. As will be discussed ingreater detail below, the electronic device 100 includes a data transferapplication that allows a user to request the transfer of data betweenaccounts at a resource server.

The electronic device 100, a computing device, includes a variety ofmodules. For example, as illustrated, the electronic device 100, mayinclude a processor 200, a memory 210, an input interface module 220, anoutput interface module 230, a communications module 240, and a cameramodule 260. As illustrated, the foregoing example modules of theelectronic device 100 are in communication over a bus 250.

The processor 200 is a hardware processor. Processor 200 may, forexample, be one or more ARM, Intel x86, PowerPC processors or the like.

The memory 210 allows data to be stored and retrieved. The memory 210may include, for example, random access memory, read-only memory, andpersistent storage. Persistent storage may be, for example, flashmemory, a solid-state drive or the like. Read-only memory and persistentstorage are a computer-readable medium. A computer-readable medium maybe organized using a file system such as may be administered by anoperating system governing overall operation of the electronic device100.

The input interface module 220 allows the electronic device 100 toreceive input signals. Input signals may, for example, correspond toinput received from a user. The input interface module 220 may serve tointerconnect the electronic device 100 with one or more input devices.Input signals may be received from input devices by the input interfacemodule 220. Input devices may, for example, include one or more of atouchscreen input, keyboard, trackball or the like. In some embodiments,all or a portion of the input interface module 220 may be integratedwith an input device. For example, the input interface module 220 may beintegrated with one of the aforementioned example input devices.

The output interface module 230 allows the electronic device 100 toprovide output signals. Some output signals may, for example allowprovision of output to a user. The output interface module 230 may serveto interconnect the electronic device 100 with one or more outputdevices. Output signals may be sent to output devices by outputinterface module 230. Output devices may include, for example, a displayscreen such as, for example, a liquid crystal display (LCD), atouchscreen display. Additionally or alternatively, output devices mayinclude devices other than screens such as, for example, a speaker,indicator lamps (such as for, example, light-emitting diodes (LEDs)),and printers. In some embodiments, all or a portion of the outputinterface module 230 may be integrated with an output device. Forexample, the output interface module 230 may be integrated with one ofthe aforementioned example output devices.

The communications module 240 allows the electronic device 100 tocommunicate with other electronic devices and/or various communicationsnetworks. For example, the communications module 240 may allow theelectronic device 100 to send or receive communications signals.Communications signals may be sent or received according to one or moreprotocols or according to one or more standards. For example, thecommunications module 240 may allow the electronic device 100 tocommunicate via a cellular data network, such as for example, accordingto one or more standards such as, for example, Global System for MobileCommunications (GSM), Code Division Multiple Access (CDMA), EvolutionData Optimized (EVDO), Long-term Evolution (LTE) or the like.Additionally or alternatively, the communications module 240 may allowthe electronic device 100 to communicate using near-field communication(NFC), via Wi-Fi™, using Bluetooth™ or via some combination of one ormore networks or protocols. Contactless payments may be made using NFC.In some embodiments, all or a portion of the communications module 240may be integrated into a component of the electronic device 100. Forexample, the communications module may be integrated into acommunications chipset.

The camera module 260 allows the electronic device 100 to capture cameradata such as images in the form of still photographs and/or motionvideo. The camera module 260 includes one or more cameras that aremounted on the electronic device 100. In particular, the electronicdevice 100 may include a display screen on a first side and at least onerear-facing camera on a second side opposite to the first side. Therear-facing cameras are located to obtain images of a subject near arear side of the electronic device 100. The camera data may be capturedin the form of an electronic signal which is produced by an image sensorassociated with each of one or more of the cameras. In at least someembodiments, the electronic device 100 operates in an operating mode inwhich the display screen acts as a viewfinder displaying image dataassociated with the rear-facing cameras.

Software comprising instructions is executed by the processor 200 from acomputer-readable medium. For example, software may be loaded intorandom-access memory from persistent storage of memory 210. Additionallyor alternatively, instructions may be executed by the processor 200directly from read-only memory of memory 210.

FIG. 3 depicts a simplified organization of software components storedin memory 210 of the electronic device 100. As illustrated thesesoftware components include an operating system 300 and a data transferapplication 310.

The operating system 300 is software. The operating system 300 allowsthe data transfer application 310 to access the processor 200, thememory 210, the input interface module 220, the output interface module230 and the communications module 240. The operating system 300 may be,for example, Apple iOS™, Google™ Android™, Linux™, Microsoft™ Windows™,or the like.

The data transfer application 310 adapts the electronic device 100, incombination with the operating system 300, to operate as a devicecapable of requesting transfer of data between user accounts at aresource server. The data transfer application 310 may be a stand-aloneapplication or integrated into another application as a sub-function orfeature. For example, the data transfer application 310 may be called asa sub-function by a mobile application that is used for making chequedeposits and/or data transfers corresponding to financial data. Inparticular, the data transfer application 310 may be part of a bankingapplication or a similar application suited for requesting transfersbetween accounts on servers of bank institutions. The data transferapplication 310 may offer, as a feature, the ability to requesttransfers between various bank accounts (e.g. chequing account, savingsaccount, etc.). In order to effect such data transfers, a mobile bankingapplication may call the data transfer application 310 when prompted bya user input to initiate a transfer process.

The data transfer application 310 may include one or more submodules.

FIG. 4 depicts a simplified organization of submodules exemplary of anembodiment of the data transfer application 310.

As illustrated, the data transfer application 310 includes a userinterface module 410 and an image capture module 420.

The user interface module 410 provides a user interface for the datatransfer application 310. In some embodiments, the provided userinterface may be visual and may include one or more screens or panelsallowing a user to configure and control various aspects of the datatransfer application 310 and to otherwise review other informationrelated to aspects of the data transfer application 310. For example, avisual user interface may be provided using a display screen accessedvia the output interface module 230 (FIG. 2). The user interface for thedata transfer application 310 may be provided as a viewfinder or apreview screen on the display screen of the electronic device 100. Morespecifically, when the data transfer application 310 is launched, atleast a portion of the display screen of the electronic device 100 maybe occupied by a viewfinder or a preview screen which shows a livepreview of a scene as captured by the camera module 260 of theelectronic device 100.

The user interface module 410 may process input provided by a user suchas may be received, for example, via the input interface module 220(FIG. 2). For example, a user may provide input for processing by theuser interface module 410 using an input device such as, for example, atouch display screen from which input is received. The input from theinput device may be received via the input interface module 220.

Additionally or alternatively, the user interface module 410 may provideone or more other forms of user interface such as, for example, anaudio-based interface which uses text-to-speech or voice recognition tointeract with a user.

The image capture module 420 is responsible for initiating andcontrolling the capture and processing of images which may be performedas a sub-function of the data transfer application 310. The imagecapture module 420 may be configurable to support capturing andprocessing images of various different types of documents. For example,the image capture module 420 may support capturing images of documentscontaining printed material thereon (e.g. identity documents, financialinstruments, tickets, receipts) as well as documents/pages that aredisplayed on an electronic display device.

Reference is now made to FIG. 5, which is a sequence diagramillustrating an example process 500 for client authentication andauthorization for accessing a protected resource. The process 500 may beimplemented as part of a protocol for authenticating a clientapplication requesting to access a resource server and authorizing theclient application to undertake an operation of a limited scope. In someexample embodiments, as in the process illustrated in FIG. 5, a clientapplication may be authorized to make an API request/call to cause anoperation to be performed at a resource server.

When an end-user launches a client application on a device, the clientapplication initiates authentication of the end-user in operation 510.In the context of an OpenID Connect implementation, the clientapplication (or relying party) generates an OpenID authenticationrequest (which may be an OAuth 2.0 authorization request to access theend-user's identity) via a browser (e.g. browser 320 of FIG. 3), inoperation 512. The client application redirects the browser to the OAuth2.0 authorization endpoint of an identity provider service (i.e. OpenIDprovider). That is, the user authentication takes place at the identityprovider, where the user's credentials will be verified. For example,the end-user may be redirected to the identity provider service by abrowser popup.

At the identity provider, the end-user will be authenticated by eitherchecking that they have a valid active session or by prompting theend-user to log in using their user credentials. A valid session may beestablished by a session cookie. In the absence of a cookie, theend-user may be prompted to provide their credentials and consent forsigning into the client application. The actual authentication of theend-user may be done in a number of different ways; in particular, theauthentication technique is not limited to traditional username/passwordlogin.

Once the end-user is authenticated, the client application is providedwith an authorization code in operation 514. In particular, the clientapplication parses the redirect Uniform Resource Locator (URL) to obtainthe authorization code. An authorization code is an intermediatecredential, which encodes the authentication of the end-user and whichmay be exchanged for an access token. An access token is used to makeauthenticated requests to a protected resource, such as an API.

After receiving the authorization code, the client application mayperform one or more intermediate operations, such as generating a uniqueidentifier of the end-user. In operation 516, the client application maycause a pair of user-specific asymmetric cryptographic keys to begenerated on the device. A public key and a private key are generatedtogether. In at least some embodiments, the private key of thepublic-private key pair is generated in a hardware-based key manager, ora “secure enclave”, on the user's device. The secure enclave is isolatedfrom the main processor of the user's device to provide an extra layerof security. When the private key is stored in the secure enclave, theprivate key itself is not handled; instead, the secure enclave isinstructed to create the key, securely store it, and perform operationswith it. The client application only receives the output of saidoperations, such as encrypted data or a cryptographic signatureverification outcome.

By specifying an access control object associated with the private keyin the secure enclave, the key can be set to be only accessible on thedevice that created it and only when the device is unlocked. The accesscontrol object may include a flag for indicating that the private keyshould be available for use in signing and verification operationsinside the secure enclave.

Once the keys have been generated, the client application submits arequest to the authorization server, in operation 518, to obtain anaccess token for use in accessing a protected resource. For example, theclient application may make a HTTP POST request to the authorizationserver. The access token may be used, for example, in makingauthenticated API calls to a resource server. As part of the request tothe authorization server, the client application submits, at least: aclient identifier uniquely identifying the client application, a useridentifier uniquely identifying an end user of the client application,and the user-specific public key generated in operation 516.

In operation 520, the authorization server validates the request for anaccess token submitted by the client application. The authorizationserver may include, or be connected to, the mobile security service 132of FIG. 1 and a security token service (included, for example, as atoken endpoint of an identity provider). As part of the operation ofvalidating the request, the authorization server may generate a requestto exchange the authorization code for a set of one or more tokens, andsubmit the request to the security token service.

On success, the security token service (and, by association, theauthorization server) returns a secure JavaScript Object Notation (JSON)Web Token (JWT) object with an ID token, an access token, and/or anoptional refresh token. In some embodiments, the tokens may be saved atthe authorization server. The end-user public key is also saved at theauthorization server. The public key may be saved in association withthe tokens (e.g. ID token, access token) which were generated as aresult of the request submitted by the client application in operation518.

In operation 522, the requested access token (and optionally, therefresh token) is provided to the client application. The access tokenmay be saved on the user's device.

In operation 524, the client application constructs a request to accessa protected resource. For example, the client application may generate arequest/call to an API associated with a resource server. The clientapplication may first create a cryptographic nonce. In some embodiments,the cryptographic nonce may include a combination of the clientidentifier, the user identifier, and a salt value (e.g. an arbitrarynumber to be used only once). A cryptographic signature is then createdby the client application. The signature may be generated based on amessage that includes a combination of a first representation of therequested access token and the cryptographic nonce. The message data (ora hash of the message data) may be encrypted with the user-specificprivate key in the secure enclave of the device. The signature itselfmay be generated in the secure enclave. The request to access theprotected resource includes the access/bearer token, the cryptographicnonce, and the digital signature.

The client application sends the request to the protected resource, inoperation 526. The protected resource, in turn, requests theauthorization server to verify the bearer token submitted by the clientapplication, in operation 528. That is, the authorization serverreceives, from a web server associated with the protected resource, arequest to validate the bearer token.

In operation 530, the authorization server validates the bearer token.The digital signature may be verified by using the public key previouslystored at the authorization server to decrypt the signature andcomparing to the original data (i.e. the access token and cryptographicnonce). The cryptographic nonce may also be verified by theauthorization server. In particular, the authorization server maycompare the cryptographic nonce against a store of nonce values toensure that the same value has not previously been used. The use ofcryptographic nonce values can help to prevent token replay attacks, inwhich a client attempts to authenticate a relying party with a securitytoken that the client has already used. By recording, in memory of theauthorization server, a cryptographic nonce associated with an accesstoken for the duration of the expiry period of said token, theauthorization server may be able to detect token replay.

In response to validating the bearer token, the authorization serversends the web server associated with the protected resource anotification indicating that the bearer token is valid, in operation532. For example, a message notifying the web server that the bearertoken is valid may be generated and signed using a private key that isspecific to the authorization server.

The web server receives the notification message (and/or the digitalsignature generated based on the message) from the authorization serverand verifies it. If the message can be verified, the web server respondsto the request (e.g. API call) of the client application to theprotected resource, in operation 534.

Reference is made to FIG. 6, which shows, in flowchart form, an exampleprocess 600 for regulating access to a protected resource. The process600 may be performed by an authorization server, or at least acombination of a security token service and a server having a tokenendpoint and communicably coupled to both a requesting clientapplication and an interface (e.g. web server, API, etc.) to a protectedresource. The authorization server functions as an intermediary betweenthe client application and the protected resource, facilitatingauthenticated requests by the client application to access the protectedresource.

In operation 602, the server receives, from a client application, afirst signal including a request to obtain an access token for accessinga protected resource, such as an API or database. The request includes aunique client identifier, a unique user identifier, and a public keyassociated with an end-user of the client application. The servervalidates the request, and transmits to the client application a secondsignal including a requested access token for accessing the protectedresource, in operation 604.

The authorization server then provides validation of access permissiongranted to the client application. More specifically, in operation 606,the authorization server receives from the protected resource a thirdsignal including a request to validate a bearer token submitted by theclient application, where the bearer token includes a digital signature.The authorization server validates the bearer token in operation 608,verifying the digital signature using the public key included in therequest in operation 602.

In response to validating the bearer token, the authorization serversends the protected resource a fourth signal indicating that the bearertoken is indeed valid in operation 610.

Reference is now made to FIG. 7, which shows an example method 700 for aclient application on a user device to gain access to a protectedresource. By way of example, the method 700 may be performed by aprocessor of a user device executing a client application, such as datatransfer application 310, which is configured to make requests/calls toan API associated with a protected resource. For example, a third-partyapplication may employ method 700 when using an open banking API thatsupports various banking-related applications and services.

The user device includes a memory, a camera module, a communicationsmodule, and a processor that is configured to implement all or parts ofthe method 700.

In operation 702, first credentials identifying a user are received onthe device. For example, a user of a mobile device may input their usercredentials on the device. The device then requests an authenticationserver to verify that the first credentials belong to a user that isauthorized to access the protected resource, in operation 704. That is,the processor transmits to an authentication server, a first signalincluding a request to verify that the first credentials are authorizedfor accessing the protected resource. The first credentials may, forexample, be compared to and validated against a database of identifiesof authorized users/entities.

When the first credentials are determined to be authorized for accessingthe protected resource, the device receives from the authenticationserver a second signal that includes an access token for use inauthenticating the user on requests to access the protected resource, inoperation 706. For example, the access token may be an OAuth token thatcan interact with one or more APIs interfacing with the protectedresource. The token may, in some embodiments, be saved on the user'sdevice upon receipt.

The user of the device can then provide one or more inputs specifyingdetails of operations which may be performed at the protected resource.More specifically, user input to the device may indicate transactiondetails which may be initiated by accessing the protected resource (oran interface, such as an API, associated therewith). An API associatedwith a protected resource may include instructions for initiatingtransfer of data from a first account to a second account at theprotected resource, such as a resource server.

An example instance of digital identity management and authorizationarises in the context of data transfers between accounts at a protectedresource server. A client application may make an API request to aresource server to effect a transfer of data between two or moredifferent accounts. In some cases, the data contained in the accountsand/or the identities of the accounts may be sensitive information whichmay be prone to appropriation by attackers. Accordingly, when processingsuch API requests, it is desirable to remove or anonymizeaccount-identifying information in communications between a requestingclient application and the resource server.

In operation 708, the device receives, from the camera module, imagedata associated with a machine-readable optical label. For example, theuser of the device may capture image data of a machine-readable opticallabel that is printed or displayed on a medium different from the device(e.g. physical printed material, a label displayed on an electronicdisplay device, etc.). The optical label encodes transaction details ofa first transaction which may be completed upon gaining access to theprotected resource. The device, or a mobile application executing on thedevice, may decode the information encoded in the machine-readableoptical label and extract the transaction details of the firsttransaction.

In at least some embodiments, the transaction details include a uniqueidentifier of the first transaction. By using unique transactionidentifiers, replay attacks or accidental double transfers of data maybe prevented. The transaction details do not, however, identify theaccounts that are involved in the first transaction. That is, for atransfer transaction between a first account and a second account, thetransaction details obtained from the image data do not indicate theidentities of the first and second accounts. The machine-readableoptical label may, in some instances, be a two-dimensional barcode thatencodes the transaction details of the first transaction (e.g. “QuickResponse (QR) Code”). The machine-readable optical label may have anexpiry time, after which the label will no longer provide transactiondetails of the first transaction.

In operation 710, the device generates a request based on thetransaction details to access the protected resource for initiating thefirst transaction, where the request includes the access token receivedfrom the authentication server. In some embodiments, the request toaccess the protected resource may be generated only upon the devicereceiving a user input providing authorization to initiate the firsttransaction. The request may also include the type and quantity of datato be transferred in the first transaction.

Reference is now made to FIG. 8, which shows, in flowchart form, anexample method 800 for regulating access to a protected resource serverfor requesting transfer of data between accounts at the resource server.The method 800 may be implemented by an authentication/authorizationserver that is communicably coupled to a client application requestingaccess to a protected resource. The authentication/authorization servermay serve as an intermediary between the client application and theprotected resource.

In operation 802, the server receives first credentials identifying auser. The first credentials may, for example, be employee credentialsidentifying a specific employee within an organization. The firstcredentials may be received when the user inputs the credentials on thedevice in a log-in prompt.

In operation 804, the server receives second credentials identifying auser account. The user account may be an account at the protectedresource, or an account that is at least accessible by an interface(e.g. API) to the protected resource. The second credentials may beinput by the user who used the first credentials to log in to the firstauthentication layer (e.g. employee authentication system). The useraccount information identified by the second credentials is thenassociated with the first credentials (e.g. employee identifier), inoperation 806.

The server then stores, in memory, an access token for use inauthenticating the user on requests to access the protected resource, inoperation 808. For example, the server may receive the access token froma different entity, such as the protected resource or anotherauthorization server interfacing with the protected resource, orgenerate the access token by itself.

In at least some embodiments, the server may receive third credentialsidentifying a second user account, different from the account identifiedby the second credentials. The second user account may be associatedwith a second user, such another individual within the same organizationor an external third-party. Accordingly, the server may store, inmemory, a second access token for use in authenticating the second useron requests to access the protected resource.

In operation 810, the server receives, from a client applicationexecuting on the user device, a request to initiate a first transaction,where the request includes transaction details derived from amachine-readable optical label.

The server then verifies that the request originated from the user, inoperation 812. In some embodiments, the server may verify that the usercredentials received from the client application match the firstcredentials.

In operation 814, in response to verifying that the request originatedfrom the authorized user, the server generates a request based on thetransaction details to access the protected resource for initiating thefirst transaction. The request includes, at least, the access tokenobtained in operation 808. Upon execution of the first transaction, asspecified by the transaction details, a transfer (e.g. of data, funds,etc.) may be effected from the first user account to the second useraccount at the protected resource.

The various embodiments presented above are merely examples and are inno way meant to limit the scope of this application. Variations of theinnovations described herein will be apparent to persons of ordinaryskill in the art, such variations being within the intended scope of thepresent application. In particular, features from one or more of theabove-described example embodiments may be selected to createalternative example embodiments including a sub-combination of featureswhich may not be explicitly described above. In addition, features fromone or more of the above-described example embodiments may be selectedand combined to create alternative example embodiments including acombination of features which may not be explicitly described above.Features suitable for such combinations and sub-combinations would bereadily apparent to persons skilled in the art upon review of thepresent application as a whole. The subject matter described herein andin the recited claims intends to cover and embrace all suitable changesin technology.

1. An electronic device comprising: a memory; a camera module; acommunications module; and a processor coupled to the memory, thecommunications module, and the camera module, the processor beingconfigured to: receive, from the camera module, image data associatedwith a machine-readable optical label, the optical label encodingtransaction details of a transfer of data to a recipient account,wherein the transaction details do not indicate an identity of therecipient account; receive a user input indicating authorization toinitiate a transfer of data, via a protected resource, from an accountassociated with the user to the recipient account; and in response toreceiving the user input, generate a request for initiating the transferof data based on the transaction details, the request including anaccess token for use in authenticating the user on requests to accessthe protected resource.
 2. The electronic device of claim 1, wherein theprotected resource comprises an application programming interface thatincludes instructions for initiating transfer of data from the accountassociated with the user to the recipient account.
 3. The electronicdevice of claim 2, wherein the transaction details do not identify theaccount associated with the user or the recipient account.
 4. Theelectronic device of claim 1, wherein the machine-readable optical labelcomprises a two-dimensional barcode encoding the transaction details ofthe transfer of data.
 5. The electronic device of claim 1, wherein theprocessor is further configured to capture the image data depicting themachine-readable optical label.
 6. The electronic device of claim 1,wherein the transaction details of the transfer of data include a uniqueidentifier of the transfer of data.
 7. The electronic device of claim 1,wherein the machine-readable optical label has an expiry time.
 8. Theelectronic device of claim 1, wherein the access token is received froman authentication server associated with the protected resource.
 9. Theelectronic device of claim 8, wherein the access token is received inresponse to a request to the authentication server to verify that firstcredentials identifying the user are authorized for accessing theprotected resource.
 10. The electronic device of claim 1, wherein therequest for initiating the transfer of data includes at least one of atype or quantity of data to be transferred to the recipient account. 11.A method comprising: receiving, from a camera module of an electronicdevice, image data associated with a machine-readable optical label, theoptical label encoding transaction details of a transfer of data to arecipient account, wherein the transaction details do not indicate anidentity of the recipient account; receiving a user input indicatingauthorization to initiate a transfer of data, via a protected resource,from an account associated with the user to the recipient account; andin response to receiving the user input, generating a request forinitiating the transfer of data based on the transaction details, therequest including an access token for use in authenticating the user onrequests to access the protected resource.
 12. The method of claim 11,wherein the protected resource comprises an application programminginterface that includes instructions for initiating transfer of datafrom the account associated with the user to the recipient account. 13.The method of claim 12, wherein the transaction details do not identifythe account associated with the user or the recipient account.
 14. Themethod of claim 11, wherein the machine-readable optical label comprisesa two-dimensional barcode encoding the transaction details of thetransfer of data.
 15. The method of claim 11, further comprisingcapturing image data depicting the machine-readable optical label. 16.The method of claim 11, wherein the transaction details of the transferof data include a unique identifier of the transfer of data.
 17. Themethod of claim 11, wherein the machine-readable optical label has anexpiry time.
 18. The method of claim 11, wherein the access token isreceived from an authentication server associated with the protectedresource.
 19. The method of claim 18, wherein the access token isreceived in response to a request to the authentication server to verifythat first credentials identifying the user are authorized for accessingthe protected resource.
 20. The method of claim 11, wherein the requestfor initiating the transfer of data includes at least one of a type orquantity of data to be transferred to the recipient account.